package
{
	/**
	 * Standard ModelLocator implementation
	 * @author Kevin Whinnery
	 * 
	 */
	[Bindable]
	public class ModelLocator
	{
		private static var initialized:Boolean = false;
		private static var singleton:ModelLocator;
		
		//private constructor - no instantiation aside from getInstance
		public function ModelLocator() {
			if (initialized) {
				throw new Error("Only one instance of ModelLocator is allowed!");
			}
			else {
				initialized = true;
			}
		}
		
		public static function getInstance():ModelLocator {
			if (singleton == null) {
				singleton = new ModelLocator();
			}
			return singleton;
		}
		
		//Shared variable definition
		public var messageLog:String="";

	}
}